home *** CD-ROM | disk | FTP | other *** search
/ SGI Developer Toolbox 6.1 / SGI Developer Toolbox 6.1 - Disc 4.iso / src / swtools / mipsABI / examples / sup / PORT / step02 / Makefile < prev    next >
Encoding:
Makefile  |  1994-08-02  |  4.3 KB  |  127 lines

  1. # Copyright (c) 1992,1991 Carnegie Mellon University
  2. # All Rights Reserved.
  3. # Permission to use, copy, modify and distribute this software and its
  4. # documentation is hereby granted, provided that both the copyright
  5. # notice and this permission notice appear in all copies of the
  6. # software, derivative works or modified versions, and any portions
  7. # thereof, and that both notices appear in supporting documentation.
  8. #
  9. # CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
  10. # CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  11. # ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
  12. #
  13. # Carnegie Mellon requests users of this software to return to
  14. #
  15. #  Software Distribution Coordinator   or   Software.Distribution@CS.CMU.EDU
  16. #  School of Computer Science
  17. #  Carnegie Mellon University
  18. #  Pittsburgh PA 15213-3890
  19. #
  20. # any improvements or extensions that they make and grant Carnegie the rights
  21. # to redistribute these changes.
  22. ######################################################################
  23. # Makefile to build sup (the client side), supfilesrv (the repository
  24. # side, and supscan (used by the repository. If you only want to sup
  25. # files from CMU, just build sup.
  26. # The header files: c.h, libc.h and sysent.h are only
  27. # necessary if you are compiling on a non-Mach system. Likewise the
  28. # files in libextra.a are normally found in libcs.a on a Mach system.
  29. # DOPRINT_VA is used by vprintf.c and should be defined if your version
  30. # of libc/doprnt.c defines the routine _doprnt_va. If it defines _doprnt
  31. # instead, leave DORPINT_VA undefined.
  32. ######################################################################
  33. #
  34. # If you need to build a sup for export outside of North America use
  35. #     "make EXPORTABLE_SYSTEM=true"
  36. # this will remove (not use) any vestiges of crypt code that is present
  37. # on the system.
  38. #
  39. # If you have crypt/crypt.c and /usr/lib/libcrypt.a, you will be building
  40. # a system that uses the SUP crypt mechanism by default.
  41. #
  42. CC=abicc
  43. LD=abild
  44. SITE            = NETBSD
  45. #SITE            = CMUCS
  46. NETBSD_DEFINES        = -UMACH -DVAR_TMP -DHAS_DAEMON
  47. AFS_DEFINES        = -DAFS -I/usr/afsws/include
  48. OSF_DEFINES        = -UMACH -DOSF -D_BSD -noshrlib -g -DNEED_VSNPRINTF -DVAR_TMP
  49. CMUCS_DEFINES        = -DMACH -DDOPRINT_VA -DNEED_VPRINTF
  50. NON_MACH_DEFINES    = -UMACH
  51. #DEFS            = -UCMUCS -UCMU  ${${SITE}_DEFINES}
  52. DEFS            = -UCMUCS -UCMU  ${NETBSD_DEFINES}
  53.  
  54. #INSTALLATION PARAMETERS
  55. NETBSD_BINDIR        = /usr/local/sbin
  56. NETBSD_MAN1        = /usr/local/man/man1
  57. NETBSD_MAN8        = /usr/local/man/man8
  58.  
  59. CFLAGS            = ${DEFS} -O -I.
  60.  
  61. SUPCL            = supcmain.o supcvers.o supcparse.o supcname.o \
  62.               supcmisc.o supcmeat.o
  63. SUPS            = scm.o scmio.o stree.o log.o supmsg.o netcrypt.o
  64. EXTRA            = atoo.o errmsg.o expand.o ffilecopy.o filecopy.o nxtarg.o  \
  65.               path.o quit.o run.o salloc.o skipto.o  vprintf.o
  66.  
  67.  
  68. PROGRAMS        = sup supscan supfilesrv
  69. MAN1            = sup.1
  70. MAN8            = supservers.8
  71.  
  72. AFS_LIBPATH        = /usr/afs/lib
  73. AFS_LIBS        = -L${AFS_LIBPATH}/afs -lkauth -lprot -L${AFS_LIBPATH} -lubik -lauth -lrxkad -lsys -ldes -lrx -llwp -lcmd -lcom_err -lc ${AFS_LIBPATH}/afs/util.a
  74.  
  75. NETBSD_LIBS        = -lutil
  76. CMUCS_LIBS        = -lsys
  77. OSF_LIBS        = -lbsd
  78. LIBS            = libextra.a
  79. sup_OFILES        = ${SUPCL} ${SUPS}
  80. supfilesrv_OFILES    = supfilesrv.o scan.o ${SUPS}
  81. supfilesrv_LIBS        = libextra.a 
  82. supscan_OFILES        = supscan.o stree.o scan.o
  83.  
  84.  
  85. all: ${PROGRAMS}
  86.  
  87. sup: ${sup_OFILES} ${LIBS}
  88.     ${CC} ${CFLAGS} -o sup ${sup_OFILES} ${LIBS} ${NETBSD_LIBS}
  89.  
  90. supfilesrv: ${supfilesrv_OFILES} ${supfilesrv_LIBS}
  91.     ${CC} ${CFLAGS} -o supfilesrv ${supfilesrv_OFILES} ${supfilesrv_LIBS} ${NETBSD_LIBS}
  92.  
  93. supscan:  ${supscan_OFILES} ${LIBS}
  94.     ${CC} ${CFLAGS} -o supscan ${supscan_OFILES} ${LIBS} ${NETBSD_LIBS}
  95.  
  96. libextra.a: ${EXTRA}
  97.     ar r libextra.a $?
  98.     ranlib libextra.a
  99.  
  100. clean cleandir:
  101.     rm -f ${PROGRAMS} libextra.a netcrypt.c *.o core a.out
  102.  
  103. install: ${PROGRAMS}
  104.     install -cs -m 555 -o bin -g bin ${PROGRAMS} ${NETBSD_BINDIR}
  105.     install -c -m 444 -o bin -g bin ${MAN1} ${NETBSD_MAN1}
  106.     install -c -m 444 -o bin -g bin ${MAN8} ${NETBSD_MAN8}
  107.  
  108. netcrypt.c: crypt.diffs
  109.     @echo "[ Using netcryptvoid.c ]"
  110.     cp netcryptvoid.c netcrypt.c
  111.  
  112. scan.o:    sup.h
  113. scm.o:    sup.h
  114. scmio.o: sup.h supmsg.h
  115. stree.o: sup.h
  116. supcmain.o: sup.h supmsg.h supcdefs.h
  117. supcmeat.o: sup.h supmsg.h supcdefs.h
  118. supcmisc.o: sup.h supmsg.h supcdefs.h
  119. supcname.o: sup.h supmsg.h supcdefs.h
  120. supcparse.o: sup.h supmsg.h supcdefs.h
  121. supfilesrv.o: sup.h supmsg.h
  122. supmsg.o: sup.h supmsg.h
  123. supscan.o: sup.h
  124. netcryptvoid.o: sup.h supmsg.h
  125. netcrypt.o: sup.h supmsg.h
  126.